#ifndef MYWIDGET_H
#define MYWIDGET_H

#include <QWidget>

class MyWidget : public QWidget
{
    Q_OBJECT

signals:
    void requestClose();

public:

    explicit MyWidget(QWidget* parent = nullptr, Qt::WindowFlags f = Qt::WindowFlags())
        : QWidget(parent, f)
    {
    }

    bool close()
    {
        emit requestClose();
        return QWidget::close();
    }

};

#endif // MYWIDGET_H
